package com.yunxin.websitebox.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.yunxin.websitebox.entity.WebsiteRole;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @Author: hdw
 * @Date: 2020/10/13 10:19
 * @Description: 角色管理Mapper接口
 * @Version: 0.0.1
 */
@Repository
public interface WebsiteRoleMapper extends BaseMapper<WebsiteRole> {

    /**
     * 根据用户ID查询角色信息
     * @param userId
     * @return
     */
    List<WebsiteRole> selectRoleCodesByUserId(Long userId);

    List<Long> selectMenuIdsByRoleId(Long roleId);

}
